class ReturnBookingEntity {
	String orderno;
	dynamic driver;
	dynamic demanddepartment;
	List<ReturnBookingOutorderdetaillist> outOrderDetailList;
	dynamic orderid;
	dynamic carno;
	dynamic phone;
	dynamic projectname;

	ReturnBookingEntity({this.orderno, this.driver, this.demanddepartment, this.outOrderDetailList, this.orderid, this.carno, this.phone});

	ReturnBookingEntity.fromJson(Map<String, dynamic> json) {
		orderno = json['orderno'];
		driver = json['driver'];
		demanddepartment = json['demanddepartment'];
		if (json['outOrderDetailList'] != null) {
			outOrderDetailList = new List<ReturnBookingOutorderdetaillist>();(json['outOrderDetailList'] as List).forEach((v) { outOrderDetailList.add(new ReturnBookingOutorderdetaillist.fromJson(v)); });
		}
		orderid = json['orderid'];
		carno = json['carno'];
		phone = json['phone'];
		projectname = json['projectname'];
	}

	Map<String, dynamic> toJson() {
		final Map<String, dynamic> data = new Map<String, dynamic>();
		data['orderno'] = this.orderno;
		data['driver'] = this.driver;
		data['demanddepartment'] = this.demanddepartment;
		if (this.outOrderDetailList != null) {
      data['outOrderDetailList'] =  this.outOrderDetailList.map((v) => v.toJson()).toList();
    }
		data['orderid'] = this.orderid;
		data['carno'] = this.carno;
		data['phone'] = this.phone;
		data['projectname'] = this.projectname;
		return data;
	}
}

class ReturnBookingOutorderdetaillist {
	dynamic creatorUserId;
	String batchno;
	String materialname;
	String creationTime;
	String lastModificationTime;
	String materialid;
	dynamic spec;
	bool isallocation;
	dynamic materiallife;
	bool isDeleted;
	String warehouseid;
	dynamic inventorytypeid;
	int realquantity;
	dynamic orderdetailno;
	dynamic model;
	String id;
	dynamic inventoryitemid;
	String baseunitname;
	double amount;
	dynamic supplierid;
	int quantity;
	dynamic seqno;
	String orderid;
	dynamic lastModifierUserId;
	dynamic baseuintid;
	double diffquantity;
	dynamic qualitytypeid;
	dynamic imageurl;
	dynamic unitchangeid;
	String tenantId;
	dynamic customerid;
	dynamic materialdate;
	String materialcode;
	String skuid;

	ReturnBookingOutorderdetaillist({this.creatorUserId, this.batchno, this.materialname, this.creationTime, this.lastModificationTime, this.materialid, this.spec, this.isallocation, this.materiallife, this.isDeleted, this.warehouseid, this.inventorytypeid, this.realquantity, this.orderdetailno, this.model, this.id, this.inventoryitemid, this.baseunitname, this.amount, this.supplierid, this.quantity, this.seqno, this.orderid, this.lastModifierUserId, this.baseuintid, this.diffquantity, this.qualitytypeid, this.imageurl, this.unitchangeid, this.tenantId, this.customerid, this.materialdate, this.materialcode, this.skuid});

	ReturnBookingOutorderdetaillist.fromJson(Map<String, dynamic> json) {
		creatorUserId = json['creatorUserId'];
		batchno = json['batchno'];
		materialname = json['materialname'];
		creationTime = json['creationTime'];
		lastModificationTime = json['lastModificationTime'];
		materialid = json['materialid'];
		spec = json['spec'];
		isallocation = json['isallocation'];
		materiallife = json['materiallife'];
		isDeleted = json['isDeleted'];
		warehouseid = json['warehouseid'];
		inventorytypeid = json['inventorytypeid'];
		if(json['realquantity']==null){
			realquantity = 0;
		}else{
			realquantity = json['realquantity'].toInt();
		}

		orderdetailno = json['orderdetailno'];
		model = json['model'];
		id = json['id'];
		inventoryitemid = json['inventoryitemid'];
		baseunitname = json['baseunitname'];
		amount = json['amount'];
		supplierid = json['supplierid'];
		quantity = json['quantity'].toInt();
		seqno = json['seqno'];
		orderid = json['orderid'];
		lastModifierUserId = json['lastModifierUserId'];
		baseuintid = json['baseuintid'];
		diffquantity = json['diffquantity'];
		qualitytypeid = json['qualitytypeid'];
		imageurl = json['imageurl'];
		unitchangeid = json['unitchangeid'];
		tenantId = json['tenantId'];
		customerid = json['customerid'];
		materialdate = json['materialdate'];
		materialcode = json['materialcode'];
		skuid = json['skuid'];
	}

	Map<String, dynamic> toJson() {
		final Map<String, dynamic> data = new Map<String, dynamic>();
		data['creatorUserId'] = this.creatorUserId;
		data['batchno'] = this.batchno;
		data['materialname'] = this.materialname;
		data['creationTime'] = this.creationTime;
		data['lastModificationTime'] = this.lastModificationTime;
		data['materialid'] = this.materialid;
		data['spec'] = this.spec;
		data['isallocation'] = this.isallocation;
		data['materiallife'] = this.materiallife;
		data['isDeleted'] = this.isDeleted;
		data['warehouseid'] = this.warehouseid;
		data['inventorytypeid'] = this.inventorytypeid;
		data['quantity'] = this.realquantity;
		data['orderdetailno'] = this.orderdetailno;
		data['model'] = this.model;
		data['orderdetailid'] = this.id;
		data['inventoryitemid'] = this.inventoryitemid;
		data['baseunitname'] = this.baseunitname;
		data['amount'] = this.amount;
		data['supplierid'] = this.supplierid;
		data['realquantity'] = this.quantity;
		data['seqno'] = this.seqno;
		data['orderid'] = this.orderid;
		data['lastModifierUserId'] = this.lastModifierUserId;
		data['baseuintid'] = this.baseuintid;
		data['diffquantity'] = this.diffquantity;
		data['qualitytypeid'] = this.qualitytypeid;
		data['imageurl'] = this.imageurl;
		data['unitchangeid'] = this.unitchangeid;
		data['tenantId'] = this.tenantId;
		data['customerid'] = this.customerid;
		data['materialdate'] = this.materialdate;
		data['materialcode'] = this.materialcode;
		data['skuid'] = this.skuid;
		return data;
	}
}
